#region Summary 

// 
// Owner : JackieHan 
// 
// Solution : LearnSolution
// 
// Project :JackieHan.DoNet.Ioc
// 
// File : EventSubscrible.cs
// 
// CopyRight : Copyright © 2009-2010 JackieHan Personal, All Rights Reserved 
// 
// Summary : 事件订阅
// 
// History : 
//			2010-08-07 13:29:50	    Create 
// 

#endregion

#region Using 

using System;
using System.Collections.Generic;

#endregion

namespace JackieHan.DoNet.Ioc.Event
{
    /// <summary> 
    /// 事件订阅
    /// </summary> 
    public class EventSubscrible
    {
        private int clickEventHandledTimes = 0;

        public event EventHandler Click;

        /// <summary>
        /// 事件触发次数
        /// </summary>
        public int ClickEventHandledTimes
        {
            get { return clickEventHandledTimes; }
            set { clickEventHandledTimes = value; }
        }

        private void ImplTest_Click(object  sender,EventArgs e)
        {
            ClickEventHandledTimes += 1;
            if (Click != null)
                Click(this, EventArgs.Empty);
        }

    }
}